public class Max{
    public static void main(String[] args) {
        int ret1 =  max(1,2);
        System.out.println(ret1);
        int ret2 = max(1,2,3);
        System.out.println(ret2);
        double ret3 = max(1.2,1.5,1.6);
        System.out.println(ret3);
    }
    public static int max(int a,int b) {
        return a>b?a:b;
    }
    public static int max(int a,int b,int c) {
        int max = max(a,b);
        max = max(max,c);
        return max;
    }
    public static double max(double a,double b,double c) {
        double max = a > b? a:b;
        max = max > c? max:c;
        return max;
    }
}

//public class Max {
//    public static void main(String[] args) {
//    int ret = max3(1,2,3);
//    System.out.println(ret);
//    }
//    public static int max2(int a,int b) {
//        return a>b?a:b;
//    }
//    public static int max3(int a,int b,int c){
//        int max = max2(a,b);
//        max = max2(max,c);
//        return max;
//    }
//}